package com.fuhao.springbootrabbit.comsumer.topic;

import com.fasterxml.jackson.databind.ObjectMapper;
import com.fuhao.springbootrabbit.constant.RabbitConstant;
import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

import java.util.Map;

/**
 * @author zhang
 * @title: DirectConsumer
 */
@Component

public class TopicConsumer2 {
    @RabbitHandler
    @RabbitListener(queues = RabbitConstant.TOPIC_QUEUE2_NAME)
    public void directConsumer(Map map){
        System.out.println("topic消费者2接收消息："+map);
    }
}
